package com.free.common.core.constant;

/**
 * 缓存常量信息
 *
 * @author free
 */
public class RedisSystemCacheConstants {

    private static final String PUSH_CID_USER_SET = "push:cid:%s";
    private static final String PUSH_USER_CID_SET = "push:user:%d";

    /**
     * 和cid关联的用户
     * @param cid
     * @return
     */
    public static String getPushCidUserSet(String cid) {
        return String.format(PUSH_CID_USER_SET,cid);
    }

    /**
     * 和用户关联的cid
     * @param userId
     * @return
     */
    public static String getPushUserCidSet(Long userId) {
        return String.format(PUSH_USER_CID_SET,userId);
    }
}
